package Chess_Flyweight_12.Flyweight;

import Chess_Flyweight_12.ChessPiece;

public class BlackFlyweight extends ChessPiece {
    private String color;

    public BlackFlyweight() {
        this.color = "黑";
    }

    public String getColor() {
        return color;
    }

    public void setColor(String color) {
        this.color = color;
    }

    @Override
    public void display(int x, int y) {
        System.out.println(color + "棋位置为" + " (" + x + ", " + y + ")");
    }
}
